www.gusucode.com > 基于Matlab的MIMO通信系统仿真 含报告;司中威;了解移动通信 > 基于Matlab的MIMO通信系统仿真 含报告;司中威;了解移动通信关键技术,了解数字通信系统仿真流程,实现基本的信道编译码、调制解调等通信模块。(好评如潮,课设拿满) 学习并实现MIMO空时处理技术 学习性能分析的思路和方法/mimo/matlab for mimo 2x2/write_int32_hex.m

    function write_int32_hex(name,A)
%
% write_int32_hex(name,A)
%
% Write elements of matrix A in .dat format, suitable for loading
% into Code Composer Studio.
%
% Elements are rounded to to 32-bit signed integer format
% and the values are stored in hex-format (little endian)

N=prod(size(A));

% convert to double and/or round to nearest integer
A=double(int32(A));

if any(A>2^31-1 | A<-2^31)
    error('One or more values are out of range')
end

fid = fopen(name,'wt');
fprintf(fid,'1651 1 0 0 %X\n',N);
fprintf(fid,'0x%08X\n',A + (A<0)*2^32);
fclose(fid);